package com.buba.commodity.controller;

import com.buba.commodity.pojo.ProductSize;
import com.buba.commodity.service.SizeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/SizeController")
public class SizeController {
    private SizeService sizeService;

    @RequestMapping("/selSize")
    public List<ProductSize> selSize(){
        List<ProductSize> list = sizeService.selSize();
        return list;
    }


    @Autowired
    @Qualifier("sizeServiceImpl")
    public void setSizeService(SizeService sizeService) {
        this.sizeService = sizeService;
    }
}
